<template>
  <NewList
    :news="news"
    :bookmarkNews="bookmarkNews"
    :addBookmark="addBookmark"
    :removeBookmark="removeBookmark"
    :hiddenNews="hideNews"
    :addHideNews="addHideNews"
  />
</template>
<script setup>
import { onMounted } from "vue";
import NewList from "@/ui/NewList.vue";
import { getEntertainmentNews } from "@/services/apiEntertainmentNews";
import { ref } from "vue";

const news = ref([]);
defineProps([
  "bookmarkNews",
  "addBookmark",
  "removeBookmark",
  "hideNews",
  "addHideNews",
]);

onMounted(async () => {
  const data = await getEntertainmentNews();
  news.value = data;
});
</script>
